<template>
    <div class="manage_page fillcontain">
        <el-row style="height: 100%;">
            <el-col
                class="nav hidden-xs-only"
                :span="4"
                style="min-height: 100%; background-color: #324057;"
            >
                <el-menu
                    background-color="#324057"
                    text-color="#fff"
                    unique-opened
                    :default-active="defaultActive"
                    style="min-height: 100%;"
                    theme="dark"
                    router
                >
                    <el-menu-item index="home">打印</el-menu-item>
                    <el-menu-item index="administration">管理</el-menu-item>
                    <el-menu-item index="upload">上传</el-menu-item>

                    <!-- <el-submenu index="1">
                        <template slot="title">
                            <i class="el-icon-goods"></i>商户
                        </template>
                        <el-menu-item  index="shopAll">总店列表</el-menu-item>
                    </el-submenu> -->
                    
                </el-menu>
            </el-col>
            <el-col
                class="manageCentent"
                :xs="{span:24}"
                :span="20"
                style="height: 100%;overflow-x: hidden;"
            >
                <keep-alive>
                    <router-view v-if="$route.meta.keepAlive"></router-view>
                </keep-alive>
                <router-view v-if="!$route.meta.keepAlive"></router-view>
            </el-col>
        </el-row>
    </div>
</template>

<script>
export default {
    computed: {
        defaultActive: function() {
            return this.$route.path.replace("/", "");
        }
    }
};
</script>


<style lang="less" scoped>
@import "../style/mixin";
.manage_page {
    .el-submenu .el-menu-item {
        min-width: 0px;
    }
}
</style>
